package com.training.service.impl.xixiaoming;

import java.util.List;

import com.training.dao.xixiaoming.motorDao;
import com.training.pojo.chengshu.MotorRoom;
import com.training.service.xixiaoming.motorService;

public class motorServiceImpl implements motorService{
	
	private motorDao motordao;
	
	public List<MotorRoom> listMotor(Integer start,Integer max) {
		System.out.println("listMotorService");
		List<MotorRoom> listmotor=motordao.listMotor(start,max);
		return listmotor;
	}

	public motorDao getMotordao() {
		return motordao;
	}

	public void setMotordao(motorDao motordao) {
		this.motordao = motordao;
	}

	public Integer getRowCount() {
		Integer rowCount=motordao.getRowCount();
		return rowCount;
	}

	public MotorRoom getMotorById(Integer id) {
		System.out.println("getMotorByIdService");
		MotorRoom motor=motordao.getMotorById(id);
		return motor;
	}

	public void saveEditMotor(MotorRoom motor) {
		motordao.saveEditMotor(motor);
	}

	public void deleMotor(Integer id) {
		motordao.deleMotor(id);
	}

	public List<MotorRoom> serachMotor(Integer uid, Integer deptid,
			String deptname, String address) {
		return motordao.serachMotor(uid, deptid, deptname, address);
	}

	public boolean checkMotorname(String motorname) {
		return motordao.checkMotorname(motorname);
	}
	

}
